package com.dj.merchant.endpoint;

import com.dj.common.response.ApiResponse;
import com.dj.merchant.model.StoreInfo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;
import com.dj.merchant.dto.StoreInfoCreateData;

import java.util.List;

/**
 * @Author : Jimmy
 * @Date : 2020/12/11 15:30
 * @Desc : dj-version-tag
 **/
@FeignClient("dj-store-api-service")
public interface StoreInfoBaseService {

//    @RequestMapping(value = "storeInfo/list",method = RequestMethod.GET,consumes = "application/json")
//    ApiResponse<StoreInfo> storeInfoGet(@RequestBody StoreInfo storeInfo);


    @RequestMapping(value = "storeInfo/list",method = RequestMethod.GET)
    ApiResponse<List<StoreInfo>> selectStoreList(@RequestBody StoreInfoCreateData storeInfo);

    @RequestMapping(value = "storeInfo/create",method = RequestMethod.POST)
    ApiResponse<Long> createStore(@RequestBody StoreInfoCreateData storeInfo);

    @RequestMapping(value = "storeInfo/appriveStatus",method = RequestMethod.GET)
    ApiResponse<Integer> updateApprive(@RequestParam(value = "id") String id
            ,@RequestParam(value = "status") String status);

    @RequestMapping(value = "storeInfo/activeStatus",method = RequestMethod.GET)
    ApiResponse<Integer> updateActive(@RequestParam(value = "id") String id
            ,@RequestParam(value = "status") String status);
}
